﻿<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml">
<head>
    <title>文本输入框</title>
    <meta http-equiv="content-type" content="text/html; charset=UTF-8" /><link href="../demo.css" rel="stylesheet" type="text/css" />

    
    <script src="../../scripts/boot.js" type="text/javascript"></script>
    
    
</head>
<body>
    <h1>文本输入框</h1>

    单行输入框：<input id="tb" class="mini-textbox" emptyText="请输入商品编号"  vtype="email"/>  <br /><br />
    密码输入框：<input class="mini-password" value="12345" /> <br /><br />
    多行输入框：<textarea class="mini-textarea" emptyText="请输入备注"></textarea> <br />

    
    <script type="text/javascript">
        mini.TextBox.prototype.setText = function (value) {
            $(".mini-textbox-input", this.el).val(value);
        }
        mini.TextBox.prototype.getText = function () {
            return $(".mini-textbox-input", this.el).val()
        }

        mini.parse();

        setTimeout(function () {
            var tb = mini.get("tb");
            tb.setText("bbb");
            alert(tb.getValue() + ":" + tb.getText());
        }, 100);

    </script>

    <div class="description">
        <h3>Description</h3>
        
    </div>
</body>
</html>
<script>
</script>